package Mypackage;


import Mypackage.Lexer.MySyntaxHighlighter;
import com.intellij.lang.Language;
import com.intellij.openapi.fileTypes.SingleLazyInstanceSyntaxHighlighterFactory;
import com.intellij.openapi.fileTypes.SyntaxHighlighter;
import com.intellij.openapi.fileTypes.SyntaxHighlighterFactory;
import org.jetbrains.annotations.NotNull;

/**
 * @author traff
 */
public class PerlLanguage extends Language {
  public static final PerlLanguage INSTANCE = new PerlLanguage();

  public PerlLanguage() {
    super("Perl");
    SyntaxHighlighterFactory.LANGUAGE_FACTORY.addExplicitExtension(this, new SingleLazyInstanceSyntaxHighlighterFactory() {
      @NotNull
      protected SyntaxHighlighter createHighlighter() {
        return new MySyntaxHighlighter();
      }
    });
  }

  @Override
  public String getDisplayName() {
    return "Perl config";
  }
}